<?php include './application/views/zhs_mobile/header.php';?>
<script>
function invested_more(){
	var page = parseInt(document.getElementById('invested_page').value);
	var str = "";
	$.ajax({
		type: "GET",
		url: "/zhs_mobile/acenter/invite_log_more/"+page,
		data: "",
		success: function(ret){
			if( ret.length >0){
		        for(var i=0;i<ret.length;i++){
					str += "<tr>";
					str += "<td>"+"第 "+ret[i].borrow_id+" 期"+"</td>";
					str += "<td>"+ret[i].add_time+"</td>";
					str += "<td>"+ret[i].account+"</td>";
					str += "<td>"+ret[i].fstatus_text+"</td>";
					str += "</tr>";
		        }
				page = page+ret.length;
				document.getElementById('invested_page').value=page;
		        var oldstr = document.getElementById('invested_tab').innerHTML;
		    	document.getElementById('invested_tab').innerHTML = oldstr+str;
			}
		},
		dataType: "json"
	});
}
</script>
<section class="invbd main">
   <h3 class="logtitle">投资记录</h3>
   <table class="wqtqb mt" id="invested_tab">
     <thead>
       <tr>
         <th>投资标的</th>
         <th>投资时间</th>
         <th>投资金额(￥)</th>
         <th>投资状态</th>
       </tr>
     </thead>
     <tbody>
       <?php foreach ($invest_list as $invest) {?>
        <tr>
         <td>第 <?php echo $invest['borrow_id'];?> 期</td>
         <td> <?php echo $invest['add_time'];?></td>
         <td> <?php echo $invest['account'];?></td>
         <td> <?php echo $invest['fstatus_text'];?> </td>
       </tr>
       <?php }?>
     </tbody>
   </table>
   <input type="hidden" id="invested_page" value="<?php echo $page;?>"/>
	<a href="javascript:invested_more()" class="membtn3" >查看更多</a>
   <br/><br/><br/><br/><br/><br/>
</section>
<?php include './application/views/zhs_mobile/footer.php';?>
